﻿<?xml version="1.0" encoding="utf-8"?>
<xsl:stylesheet version="1.0" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:msxsl="urn:schemas-microsoft-com:xslt" exclude-result-prefixes="msxsl">
  <xsl:output method="html" indent="yes"/>

  <xsl:template match="/">
	<html>
	  <head>
		<title>Changes Log Viewer</title>
		<link href="css/LogView.css" type="text/css" rel="stylesheet"/>

		<style type="text/css">
		  body {background-color: white; padding:0; margin:10px 10px 20px 10px; color:black; font-size: 0.8em;font-family: "MS Shell Dlg", sans-serif;}

		  h1,h2 {font-family: "Segoe UI",Tahoma, Verdana, sans-serif; margin:0; padding:0;}
		  h1 {color:#3aba07; letter-spacing:-1px; font-weight:normal;font-size: 1.8em; margin:0;padding:0;}
		  h2 {color:#1987cc; font-size: 1.2em; margin:10px 0 2px 0;padding:3px 0;border-top:1px solid #dcf7fd;}

		  .mplsession	{padding: 0 0 20px 0;}

		  .mplsession ul {list-style-type:none;margin:0;padding:0;border-top: 1px solid #6ed6f3;border-bottom:4px solid #f7feef;font-family: "Segoe UI",Tahoma, Verdana, sans-serif;font-size:0.95em;color:#333333;}
		  .mplsession ul li {padding:0 7px 2px 7px;background:#dcf7fd;border-top:2px solid #edfbfe;border-bottom:1px solid #6ed6f3;}
		  .mplsession ul li.first {background:#dcf7fd;border-top:2px solid #fff;}
		  .mplsession ul li.second {background:#edfbfe;border-top:2px solid #fff;}
		  .red {color:red;}
		</style>
	  </head>
	  <body>
		<!--<table border="0" cellpadding="2" cellspacing="0" width="100%">
					<tr>
						<td colspan="12">Changes Log Viewer v1.0.0</td>
					</tr>
				</table>-->
		<h1>Changes Log Viewer v1.0.0.0</h1>

		<div class="mplsession">
		  <xsl:for-each select="changeLog/logEntry">
			<h2>
			  Version: <span class="red">
				<xsl:value-of select="@version"></xsl:value-of>
			  </span>,
			  Date: <span class="red">
				<xsl:value-of select="@timeStamp"></xsl:value-of>
			  </span>,
			  Author: <span class="red">
				<xsl:value-of select="@author"></xsl:value-of>
			  </span>
			</h2>
			<ul>
			  <xsl:for-each select="changes">
				<li>
				  <xsl:if test="position() mod 2 = 0">
					<xsl:attribute name="class">first</xsl:attribute>
				  </xsl:if>
				  <xsl:if test="position() mod 2 = 0">
					<xsl:attribute name="class">second</xsl:attribute>
				  </xsl:if>
				  <xsl:value-of select="text()"></xsl:value-of>
				</li>
			  </xsl:for-each>
			</ul>
		  </xsl:for-each>
		</div>
	  </body>
	</html>
  </xsl:template>
</xsl:stylesheet>
